package router

import (
	"github.com/gin-gonic/gin"
	"user_bff/controller"
	"user_bff/middleware"
)

func InitRouter() *gin.Engine {
	router := gin.Default()
	router.POST("/user/login", controller.UserLogin) //用户登录注册
	router.Use(middleware.UserAuth())
	router.GET("/detail/book", controller.DetailBook) //漫画详情
	router.GET("/book/list", controller.BookList)     //漫画列表
	router.GET("/book/lists", controller.BookLists)   //漫画列表(分类)
	return router
}
